# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
# Contributor: Florian Pritz <bluewind@xinu.at>
# Contributor: Martchus <martchus@gmx.net>

pkgname=libfilezilla
epoch=1
pkgver=0.45.0
pkgrel=1
pkgdesc='Small and modern C++ library, offering some basic functionality to build high-performing, platform-independent programs'
url='https://lib.filezilla-project.org/'
arch=('loong64' 'x86_64')
license=('GPL')
depends=('glibc' 'gcc-libs' 'nettle' 'gnutls' 'libnettle.so' 'libhogweed.so')
makedepends=(clang)
checkdepends=('cppunit')
provides=('libfilezilla.so')
source=(https://download.filezilla-project.org/libfilezilla/libfilezilla-${pkgver}.tar.xz)
sha512sums=('304838e8cf6e644378c0727bc8b9d2f87287a646db4cb765a04d156717f8c233b8a34085049e4893ec345a1a1d576f0ba33df705dee022e16ff433cddd926ce0')
b2sums=('c85c07d23381d63c6f959e9721fa898982c692cafcd863cd15da7fce7e486bf2031b0d0e1fb18efeb271d1aa497eabe0dff4c14f8ff89fbe3ed880a737fc8f6e')

build() {
  cd ${pkgname}-${pkgver}
  export CXX=clang++
  export CC=clang
  ./configure \
    --prefix=/usr \
    --disable-static
  make
}

check() {
  cd ${pkgname}-${pkgver}
  # LANG needed to fix string_test::test_conversion2
  LANG=en_US.UTF-8 make check
}

package() {
  cd ${pkgname}-${pkgver}
  make DESTDIR="${pkgdir}" install
}

# vim: ts=2 sw=2 et:
